package com.patrol.pojo;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;

/**
 * @author zsc
 * @version 1.0
 * @description: TODO
 * @date 2022/1/2 16:10
 */
@Data
@NoArgsConstructor
@TableName(value = "user")
public class User {
    @TableId(value = "userId", type = IdType.AUTO)
    private Integer userId;

    @TableField("username")
    private String username;

    @TableField("realName")
    private String realName;

    @TableField("password")
    private String password;

    @TableField("sex")
    private int sex;

    @TableField("img")
    private String img;

    @TableField("authority")
    private Integer authority;

    @TableField("email")
    private String email;

    @TableField("tel")
    private String tel;

    @TableField("is_assigned")
    private Integer isAssigned;

    @ApiModelProperty(value = "逻辑删除")
    @TableLogic
    private Integer isDeleted;

    public User(Integer userId, String username, String realName, int sex, String tel, String email){
        this.userId = userId;
        this.username = username;
        this.realName = realName;
        this.sex = sex;
        this.tel = tel;
        this.email = email;
    }
}
